package com.liang.serviceImpl;

import java.util.Map;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.liang.dao.UserDao;
import com.liang.pojo.User;
import com.liang.service.UserService;
@Service
public class UserServiceImpl implements UserService{
	@Autowired
	UserDao userDao;
//	private UserDao userDao;
//	public void setUserDao(UserDao userDao) {
//		this.userDao=userDao;
//	}
	/*
	 * public User selectUserByUsername(String username) { return
	 * userDao.selectUserByUsername(username); }
	 */
	public User selectUserByUsername(Map<String, Object> map) {
		return userDao.selectUserByUsername(map);
	}
	public int insertUser(User user) {
		return userDao.insertUser(user);
	}
	public User selectUserById(int id) {
		return userDao.selectUserById(id);
	}

}
